# Set the working directory to the project folder.
project_folder <- "."
setwd(project_folder)
library(Seurat)
library(ggplot2)
library(ggalluvial)
library(grid)
library(forcats)
library(see)
library(dplyr)
library(gghalves)
library(viridis)
library(stringr)
library(RColorBrewer)
library(kableExtra)
library(ggpubr)
library(rstatix)
library(clusterProfiler)
library(EnhancedVolcano)
library(introdataviz)
cols1 <- c(`0 CD8+ Eff mem (EM)` = "#A6CEE3", `1 CD8+ Eff cytotox (Ecyt)` = "#1F78B4",
`3 CD4+ Naive/SCM` = "#33A02C", `6 CD4+ Central/Effector memory (CM/EM)` = "#FDBF6F",
`9 γδ Tcells` = "#6A3D9A", `Proliferative cells` = "#F7D764")
cols2 <- c(`0 CD8+ Eff mem (EM)` = "#A6CEE3", `1 CD8+ Eff cytotox (Ecyt)` = "#1F78B4",
`2 Early prolif: HMGN+/HMGB+/PCNA+ cells` = "#B2DF8A", `3 CD4+ Naive/SCM` = "#33A02C",
`4 Early prolif: MCM3/5/7+ PCNA+ cells` = "#FB9A99", `5 Late prolif: histones enriched MKI67+ cells` = "#E31A1C",
`6 CD4+ Central/Effector memory (CM/EM)` = "#FDBF6F", `7 Ribosomal/Mitocondrial/Degradated cells` = "#FF7F00",
`8 Late prolif: CDK+/CDC+/AURKA+ MIK67+ cells` = "#CAB2D6", `9 γδ Tcells` = "#6A3D9A")
cols3 <- c(`CAR+` = "#66c2a5", `CAR-` = "#fc8d62")
cols4 <- c("#264653", "#2a9d8f", "#e9c46a", "#f4a261", "#e76f51")
cols5 <- c(IP = "#4E6AAB", Peak = "#e78ac3")
cols6 <- c(CD4 = "#147D2C", CD8 = "#F5C936", Unknown = "#7f7f7f", `CD4- CD8-` = "#38369A")
cols7 <- c("#F8766D", "#00BA38", "#619CFF")
cols8 <- c("#E69F00FF", "#56B4E9FF", "#009E73FF", "#F0E442FF")
integrated.obj <- readRDS("integrated.obj.rds")
Define genes to analyse.
activation_genes <- c("CD28", "CD40LG", "TNFRSF4", "TNFRSF9", "CD74", "HLA-DBR1",
"NKB1", "ICOS", "CD27", "CD25", "CD69")
integrated.obj <- AddModuleScore(object = integrated.obj, features = list(activation_genes),
name = "Act.MGM")
## Warning: The following features are not present in the object: HLA-DBR1, NKB1,
## CD25, not searching for symbol synonyms
FeaturePlot(integrated.obj, features = activation_genes)
## Warning in FetchData.Seurat(object = object, vars = c(dims, "ident", features),
## : The following requested variables were not found: HLA-DBR1, NKB1, CD25
integrated.obj.Peak <- subset(x = integrated.obj, subset = Timepoint == "IP")
# Signature expression
aux_df1 <- data.frame(seurat_clusters = Idents(integrated.obj.Peak), integrated.obj.Peak[[]],
FetchData(integrated.obj.Peak, vars = activation_genes, slot = "data"))
## Warning in FetchData.Seurat(integrated.obj.Peak, vars = activation_genes, : The
## following requested variables were not found: HLA-DBR1, NKB1, CD25
Print the average, max and sd for each gene
aux_df1 %>%
group_by(Patient_id, Timepoint, Class1) %>%
summarise_at(vars(one_of(activation_genes)), list(mean = mean, max = max, sd = sd)) %>%
kbl() %>%
kable_styling(bootstrap_options = c("striped", "hover")) %>%
scroll_box(width = "100%", height = "500px")
## Warning: Unknown columns: `HLA-DBR1`, `NKB1`, `CD25`
| Patient_id | Timepoint | Class1 | CD28_mean | CD40LG_mean | TNFRSF4_mean | TNFRSF9_mean | CD74_mean | ICOS_mean | CD27_mean | CD69_mean | CD28_max | CD40LG_max | TNFRSF4_max | TNFRSF9_max | CD74_max | ICOS_max | CD27_max | CD69_max | CD28_sd | CD40LG_sd | TNFRSF4_sd | TNFRSF9_sd | CD74_sd | ICOS_sd | CD27_sd | CD69_sd |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| patient1 | IP | CAR+ | 0.2032246 | 0.4474325 | 0.0151699 | 0.0132654 | 3.649087 | 0.1740156 | 0.9782899 | 0.7893528 | 2.742635 | 3.831090 | 1.664776 | 2.773125 | 5.894663 | 2.153638 | 3.294562 | 3.061552 | 0.4687367 | 0.7957521 | 0.1288320 | 0.1406676 | 0.7928318 | 0.4120311 | 0.8633980 | 0.8147787 |
| patient1 | IP | CAR- | 0.1819366 | 0.2889402 | 0.0060565 | 0.0081733 | 3.772949 | 0.1671164 | 1.0449855 | 0.7851441 | 2.507998 | 3.605574 | 1.868636 | 2.704251 | 5.624653 | 2.343362 | 3.514258 | 3.982876 | 0.4684201 | 0.6742635 | 0.0944544 | 0.1043026 | 0.6945903 | 0.4268390 | 0.9198547 | 0.8596306 |
| patient2 | IP | CAR+ | 0.2794793 | 0.2681035 | 0.0269683 | 0.0245779 | 4.549719 | 0.1626954 | 0.1689869 | 0.8437777 | 3.503515 | 3.597722 | 2.314096 | 2.580975 | 6.459877 | 2.805783 | 3.004467 | 4.240553 | 0.6717792 | 0.6849205 | 0.2106883 | 0.2065098 | 0.8538531 | 0.5207312 | 0.5504364 | 1.1184955 |
| patient2 | IP | CAR- | 0.2202422 | 0.1845875 | 0.0087081 | 0.0264293 | 3.857272 | 0.1509738 | 0.1669816 | 1.3033588 | 2.938584 | 3.251708 | 2.396987 | 2.339117 | 5.719099 | 2.830207 | 3.017315 | 4.751086 | 0.6291649 | 0.5975152 | 0.1333319 | 0.2138125 | 0.9632451 | 0.5130267 | 0.5849974 | 1.2823109 |
| patient3 | IP | CAR+ | 0.2334054 | 0.4018521 | 0.0672190 | 0.0211645 | 3.023431 | 0.1776469 | 0.6213310 | 0.7513492 | 3.232025 | 3.539359 | 2.632121 | 2.586069 | 5.681022 | 2.471989 | 3.173179 | 3.707736 | 0.5828129 | 0.7832169 | 0.3106180 | 0.1792936 | 1.0160658 | 0.4970965 | 0.8867879 | 0.9549400 |
| patient3 | IP | CAR- | 0.1673013 | 0.2368321 | 0.0222979 | 0.0359687 | 2.848937 | 0.1880342 | 0.6218271 | 0.8341690 | 3.413882 | 3.476551 | 2.277941 | 2.944534 | 5.264283 | 2.594053 | 3.297379 | 3.719444 | 0.5278786 | 0.6522536 | 0.1966603 | 0.2561078 | 1.1008412 | 0.5276756 | 0.9371440 | 1.0313439 |
| patient4 | IP | CAR+ | 0.1036454 | 0.4108187 | 0.0242136 | 0.0192158 | 3.465074 | 0.1289096 | 0.8560974 | 1.1911339 | 2.782725 | 3.332797 | 2.034856 | 2.405659 | 5.683235 | 2.878519 | 3.354256 | 3.443542 | 0.3873189 | 0.7427409 | 0.1811134 | 0.1622388 | 0.8899900 | 0.4127893 | 0.9212579 | 0.9617711 |
| patient4 | IP | CAR- | 0.0790173 | 0.1842659 | 0.0067281 | 0.0475107 | 3.905367 | 0.1155074 | 0.7206828 | 1.2312237 | 3.293625 | 3.209271 | 2.334051 | 3.383802 | 5.901725 | 2.999922 | 3.661372 | 3.844274 | 0.3675451 | 0.5601953 | 0.1082358 | 0.2863148 | 1.0704705 | 0.4215263 | 1.0037946 | 1.0808588 |
| patient5 | IP | CAR+ | 0.3419305 | 0.4275277 | 0.0019027 | 0.0170120 | 3.809501 | 0.3595868 | 0.5947328 | 0.6664258 | 3.216728 | 4.195087 | 1.660966 | 2.419071 | 5.932217 | 3.522941 | 3.491865 | 4.406818 | 0.7164245 | 0.8525841 | 0.0471570 | 0.1624464 | 0.9630692 | 0.7347437 | 0.9409721 | 0.9915923 |
| patient5 | IP | CAR- | 0.2792884 | 0.4001225 | 0.0000000 | 0.0288433 | 3.662810 | 0.2951297 | 0.8958281 | 0.6999004 | 3.226201 | 3.230468 | 0.000000 | 2.316564 | 5.610964 | 2.924298 | 3.566537 | 4.033406 | 0.6442354 | 0.8075789 | 0.0000000 | 0.2035010 | 0.9114614 | 0.6435492 | 1.0453935 | 0.9706036 |
FeaturePlot(integrated.obj, features = "Act.MGM1")
# CAR+/CAR-
ggplot(aux_df1, aes(x = fct_reorder(Class1, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = Class1)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols3)
# CD4/CD8
aux_df1 <- aux_df1[which(aux_df1$final_criteria != "Unknown"), ]
ggplot(aux_df1, aes(x = fct_reorder(final_criteria, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = final_criteria)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols6)
ggplot(aux_df1, aes(x = fct_reorder(Class1, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = final_criteria)) + geom_split_violin() + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols6)
integrated.obj.Peak <- subset(x = integrated.obj, subset = Timepoint == "Peak")
aux_df1 <- data.frame(seurat_clusters = Idents(integrated.obj.Peak), integrated.obj.Peak[[]],
FetchData(integrated.obj.Peak, vars = activation_genes, slot = "data"))
## Warning in FetchData.Seurat(integrated.obj.Peak, vars = activation_genes, : The
## following requested variables were not found: HLA-DBR1, NKB1, CD25
Print the average, max and sd for each gene
aux_df1 %>%
group_by(Patient_id, Timepoint, Class1) %>%
summarise_at(vars(one_of(activation_genes)), list(mean = mean, max = max, sd = sd)) %>%
kbl() %>%
kable_styling(bootstrap_options = c("striped", "hover")) %>%
scroll_box(width = "100%", height = "500px")
## Warning: Unknown columns: `HLA-DBR1`, `NKB1`, `CD25`
| Patient_id | Timepoint | Class1 | CD28_mean | CD40LG_mean | TNFRSF4_mean | TNFRSF9_mean | CD74_mean | ICOS_mean | CD27_mean | CD69_mean | CD28_max | CD40LG_max | TNFRSF4_max | TNFRSF9_max | CD74_max | ICOS_max | CD27_max | CD69_max | CD28_sd | CD40LG_sd | TNFRSF4_sd | TNFRSF9_sd | CD74_sd | ICOS_sd | CD27_sd | CD69_sd |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| patient1 | Peak | CAR+ | 0.3627902 | 0.0239788 | 0.0008582 | 0.2607525 | 4.203406 | 0.0622529 | 1.9005337 | 0.9428480 | 2.950523 | 3.404457 | 1.957659 | 3.302408 | 6.358915 | 2.488029 | 4.330509 | 4.041383 | 0.7211257 | 0.2178625 | 0.0409897 | 0.6334359 | 0.7651602 | 0.3150630 | 1.1067263 | 1.044877 |
| patient1 | Peak | CAR- | 0.1913131 | 0.0703242 | 0.0000000 | 0.0673668 | 3.594059 | 0.0593826 | 0.7344711 | 1.0785020 | 2.891553 | 2.784861 | 0.000000 | 2.947666 | 6.724743 | 2.620819 | 3.796418 | 3.785936 | 0.5414251 | 0.3468586 | 0.0000000 | 0.3387592 | 1.0793991 | 0.3139337 | 1.1058965 | 1.089465 |
| patient2 | Peak | CAR+ | 0.1649673 | 0.0373742 | 0.0000000 | 0.0440195 | 3.488778 | 0.0879091 | 0.5882039 | 1.2325634 | 3.088088 | 3.157958 | 0.000000 | 2.832461 | 5.603116 | 2.394267 | 3.516896 | 3.935099 | 0.5611679 | 0.2840945 | 0.0000000 | 0.3075817 | 0.9824115 | 0.3999162 | 1.0255506 | 1.249697 |
| patient2 | Peak | CAR- | 0.0729409 | 0.0325194 | 0.0200617 | 0.0205974 | 3.454619 | 0.0685784 | 0.2450133 | 1.3602044 | 2.484494 | 2.683933 | 2.600378 | 2.411182 | 5.454322 | 2.720268 | 4.281721 | 4.078757 | 0.3391582 | 0.2414754 | 0.1957288 | 0.1931668 | 1.0083317 | 0.3310355 | 0.6681393 | 1.211465 |
| patient3 | Peak | CAR+ | 0.3627520 | 0.0322195 | 0.0000000 | 0.0646778 | 2.812122 | 0.1120834 | 0.9173257 | 1.5548438 | 3.298215 | 2.729210 | 0.000000 | 2.936892 | 5.073486 | 3.057955 | 3.666001 | 4.464503 | 0.8264029 | 0.2587836 | 0.0000000 | 0.3678444 | 1.3332435 | 0.4707304 | 1.1765913 | 1.365613 |
| patient3 | Peak | CAR- | 0.2016444 | 0.0803131 | 0.0077465 | 0.0154524 | 2.563344 | 0.1173346 | 0.7340135 | 1.3066376 | 2.890750 | 2.833213 | 2.205085 | 2.956552 | 5.280605 | 3.441517 | 3.687588 | 4.158982 | 0.5922904 | 0.3821949 | 0.1198768 | 0.1811185 | 1.3257329 | 0.4633052 | 1.0448009 | 1.204572 |
| patient4 | Peak | CAR+ | 0.1943009 | 0.0493635 | 0.0000000 | 0.1480889 | 3.993479 | 0.0917020 | 1.2380745 | 1.0357098 | 2.840016 | 2.995400 | 0.000000 | 2.797789 | 5.596637 | 3.341898 | 3.759834 | 3.731695 | 0.5474784 | 0.3157714 | 0.0000000 | 0.4768167 | 0.8868135 | 0.4063849 | 1.1300259 | 1.084852 |
| patient4 | Peak | CAR- | 0.1224278 | 0.0802020 | 0.0013005 | 0.0108890 | 3.574894 | 0.1193289 | 0.2880645 | 0.9882553 | 3.029411 | 3.262917 | 2.326511 | 2.850702 | 5.418546 | 3.029411 | 3.593488 | 3.789069 | 0.4674077 | 0.3973381 | 0.0550047 | 0.1419216 | 1.1215928 | 0.4682750 | 0.7435651 | 1.162460 |
| patient5 | Peak | CAR+ | 0.1489820 | 0.0296727 | 0.0000000 | 0.0648870 | 3.279515 | 0.0968585 | 1.5172309 | 1.0504938 | 2.823479 | 2.849934 | 0.000000 | 2.896389 | 5.075855 | 2.253173 | 3.899294 | 3.997759 | 0.4853103 | 0.2435035 | 0.0000000 | 0.3132820 | 0.9454487 | 0.3746767 | 1.0952072 | 1.072427 |
| patient5 | Peak | CAR- | 0.1148940 | 0.0582123 | 0.0000000 | 0.0472712 | 2.927868 | 0.0795384 | 1.1184764 | 1.2214102 | 3.046429 | 2.672986 | 0.000000 | 2.844580 | 5.379268 | 2.709296 | 4.177422 | 3.976987 | 0.4348365 | 0.3198854 | 0.0000000 | 0.2940132 | 1.1507081 | 0.3543391 | 1.1572611 | 1.142109 |
FeaturePlot(integrated.obj, features = "Act.MGM1")
# CAR+/CAR-
ggplot(aux_df1, aes(x = fct_reorder(Class1, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = Class1)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols3)
# CD4/CD8
aux_df1 <- aux_df1[which(aux_df1$final_criteria != "Unknown"), ]
ggplot(aux_df1, aes(x = fct_reorder(final_criteria, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = final_criteria)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols6)
integrated.obj.Peak <- subset(x = integrated.obj, subset = Class1 == "CAR+")
aux_df1 <- data.frame(seurat_clusters = Idents(integrated.obj.Peak), integrated.obj.Peak[[]],
FetchData(integrated.obj.Peak, vars = activation_genes, slot = "data"))
## Warning in FetchData.Seurat(integrated.obj.Peak, vars = activation_genes, : The
## following requested variables were not found: HLA-DBR1, NKB1, CD25
Print the average, max and sd for each gene
aux_df1 %>%
group_by(Patient_id, Timepoint, Class1) %>%
summarise_at(vars(one_of(activation_genes)), list(mean = mean, max = max, sd = sd)) %>%
kbl() %>%
kable_styling(bootstrap_options = c("striped", "hover")) %>%
scroll_box(width = "100%", height = "500px")
## Warning: Unknown columns: `HLA-DBR1`, `NKB1`, `CD25`
| Patient_id | Timepoint | Class1 | CD28_mean | CD40LG_mean | TNFRSF4_mean | TNFRSF9_mean | CD74_mean | ICOS_mean | CD27_mean | CD69_mean | CD28_max | CD40LG_max | TNFRSF4_max | TNFRSF9_max | CD74_max | ICOS_max | CD27_max | CD69_max | CD28_sd | CD40LG_sd | TNFRSF4_sd | TNFRSF9_sd | CD74_sd | ICOS_sd | CD27_sd | CD69_sd |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| patient1 | IP | CAR+ | 0.2032246 | 0.4474325 | 0.0151699 | 0.0132654 | 3.649087 | 0.1740156 | 0.9782899 | 0.7893528 | 2.742635 | 3.831090 | 1.664776 | 2.773125 | 5.894663 | 2.153638 | 3.294562 | 3.061552 | 0.4687367 | 0.7957521 | 0.1288320 | 0.1406676 | 0.7928318 | 0.4120311 | 0.8633980 | 0.8147787 |
| patient1 | Peak | CAR+ | 0.3627902 | 0.0239788 | 0.0008582 | 0.2607525 | 4.203406 | 0.0622529 | 1.9005337 | 0.9428480 | 2.950523 | 3.404457 | 1.957659 | 3.302408 | 6.358915 | 2.488029 | 4.330509 | 4.041383 | 0.7211257 | 0.2178625 | 0.0409897 | 0.6334359 | 0.7651602 | 0.3150630 | 1.1067263 | 1.0448767 |
| patient2 | IP | CAR+ | 0.2794793 | 0.2681035 | 0.0269683 | 0.0245779 | 4.549719 | 0.1626954 | 0.1689869 | 0.8437777 | 3.503515 | 3.597722 | 2.314096 | 2.580975 | 6.459877 | 2.805783 | 3.004467 | 4.240553 | 0.6717792 | 0.6849205 | 0.2106883 | 0.2065098 | 0.8538531 | 0.5207312 | 0.5504364 | 1.1184955 |
| patient2 | Peak | CAR+ | 0.1649673 | 0.0373742 | 0.0000000 | 0.0440195 | 3.488778 | 0.0879091 | 0.5882039 | 1.2325634 | 3.088088 | 3.157958 | 0.000000 | 2.832461 | 5.603116 | 2.394267 | 3.516896 | 3.935099 | 0.5611679 | 0.2840945 | 0.0000000 | 0.3075817 | 0.9824115 | 0.3999162 | 1.0255506 | 1.2496967 |
| patient3 | IP | CAR+ | 0.2334054 | 0.4018521 | 0.0672190 | 0.0211645 | 3.023431 | 0.1776469 | 0.6213310 | 0.7513492 | 3.232025 | 3.539359 | 2.632121 | 2.586069 | 5.681022 | 2.471989 | 3.173179 | 3.707736 | 0.5828129 | 0.7832169 | 0.3106180 | 0.1792936 | 1.0160658 | 0.4970965 | 0.8867879 | 0.9549400 |
| patient3 | Peak | CAR+ | 0.3627520 | 0.0322195 | 0.0000000 | 0.0646778 | 2.812122 | 0.1120834 | 0.9173257 | 1.5548438 | 3.298215 | 2.729210 | 0.000000 | 2.936892 | 5.073486 | 3.057955 | 3.666001 | 4.464503 | 0.8264029 | 0.2587836 | 0.0000000 | 0.3678444 | 1.3332435 | 0.4707304 | 1.1765913 | 1.3656132 |
| patient4 | IP | CAR+ | 0.1036454 | 0.4108187 | 0.0242136 | 0.0192158 | 3.465074 | 0.1289096 | 0.8560974 | 1.1911339 | 2.782725 | 3.332797 | 2.034856 | 2.405659 | 5.683235 | 2.878519 | 3.354256 | 3.443542 | 0.3873189 | 0.7427409 | 0.1811134 | 0.1622388 | 0.8899900 | 0.4127893 | 0.9212579 | 0.9617711 |
| patient4 | Peak | CAR+ | 0.1943009 | 0.0493635 | 0.0000000 | 0.1480889 | 3.993479 | 0.0917020 | 1.2380745 | 1.0357098 | 2.840016 | 2.995400 | 0.000000 | 2.797789 | 5.596637 | 3.341898 | 3.759834 | 3.731695 | 0.5474784 | 0.3157714 | 0.0000000 | 0.4768167 | 0.8868135 | 0.4063849 | 1.1300259 | 1.0848520 |
| patient5 | IP | CAR+ | 0.3419305 | 0.4275277 | 0.0019027 | 0.0170120 | 3.809501 | 0.3595868 | 0.5947328 | 0.6664258 | 3.216728 | 4.195087 | 1.660966 | 2.419071 | 5.932217 | 3.522941 | 3.491865 | 4.406818 | 0.7164245 | 0.8525841 | 0.0471570 | 0.1624464 | 0.9630692 | 0.7347437 | 0.9409721 | 0.9915923 |
| patient5 | Peak | CAR+ | 0.1489820 | 0.0296727 | 0.0000000 | 0.0648870 | 3.279515 | 0.0968585 | 1.5172309 | 1.0504938 | 2.823479 | 2.849934 | 0.000000 | 2.896389 | 5.075855 | 2.253173 | 3.899294 | 3.997759 | 0.4853103 | 0.2435035 | 0.0000000 | 0.3132820 | 0.9454487 | 0.3746767 | 1.0952072 | 1.0724268 |
FeaturePlot(integrated.obj, features = "Act.MGM1")
# IP/Peak
ggplot(aux_df1, aes(x = fct_reorder(Timepoint, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = Timepoint)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols5)
# CD4/CD8
aux_df1 <- aux_df1[which(aux_df1$final_criteria != "Unknown"), ]
ggplot(aux_df1, aes(x = fct_reorder(final_criteria, Act.MGM1, .fun = median, .desc = TRUE),
y = Act.MGM1, fill = final_criteria)) + geom_violin(scale = "width") + geom_boxplot(outlier.shape = NA,
width = 0.1) + theme_classic() + theme(axis.text.x = element_text(size = 16),
axis.text.y = element_text(size = 16)) + theme(axis.text.x = element_text(angle = 90,
vjust = 0.5, hjust = 1)) + xlab("") + scale_fill_manual(values = cols6)
sessionInfo()
## R version 4.3.0 (2023-04-21)
## Platform: aarch64-apple-darwin20 (64-bit)
## Running under: macOS Ventura 13.4.1
##
## Matrix products: default
## BLAS: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRblas.0.dylib
## LAPACK: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRlapack.dylib; LAPACK version 3.11.0
##
## locale:
## [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
##
## time zone: Europe/Madrid
## tzcode source: internal
##
## attached base packages:
## [1] grid stats graphics grDevices utils datasets methods
## [8] base
##
## other attached packages:
## [1] introdataviz_0.0.0.9003 EnhancedVolcano_1.18.0 ggrepel_0.9.3
## [4] clusterProfiler_4.8.1 rstatix_0.7.2 ggpubr_0.6.0
## [7] kableExtra_1.3.4 RColorBrewer_1.1-3 stringr_1.5.0
## [10] viridis_0.6.3 viridisLite_0.4.2 gghalves_0.1.4
## [13] dplyr_1.1.2 see_0.7.5 forcats_1.0.0
## [16] ggalluvial_0.12.5 ggplot2_3.4.2 SeuratObject_4.1.3
## [19] Seurat_4.3.0 knitr_1.43
##
## loaded via a namespace (and not attached):
## [1] RcppAnnoy_0.0.20 splines_4.3.0 later_1.3.1
## [4] ggplotify_0.1.0 bitops_1.0-7 tibble_3.2.1
## [7] polyclip_1.10-4 lifecycle_1.0.3 globals_0.16.2
## [10] lattice_0.21-8 MASS_7.3-60 backports_1.4.1
## [13] magrittr_2.0.3 plotly_4.10.1 sass_0.4.6
## [16] rmarkdown_2.21 jquerylib_0.1.4 yaml_2.3.7
## [19] httpuv_1.6.11 sctransform_0.3.5 sp_1.6-0
## [22] spatstat.sparse_3.0-1 reticulate_1.28 cowplot_1.1.1
## [25] pbapply_1.7-0 DBI_1.1.3 abind_1.4-5
## [28] zlibbioc_1.46.0 rvest_1.0.3 Rtsne_0.16
## [31] purrr_1.0.1 ggraph_2.1.0 BiocGenerics_0.46.0
## [34] RCurl_1.98-1.12 yulab.utils_0.0.6 tweenr_2.0.2
## [37] GenomeInfoDbData_1.2.10 enrichplot_1.20.0 IRanges_2.34.0
## [40] S4Vectors_0.38.1 irlba_2.3.5.1 listenv_0.9.0
## [43] spatstat.utils_3.0-3 tidytree_0.4.2 goftest_1.2-3
## [46] spatstat.random_3.1-5 fitdistrplus_1.1-11 parallelly_1.35.0
## [49] svglite_2.1.1 leiden_0.4.3 codetools_0.2-19
## [52] ggforce_0.4.1 DOSE_3.26.1 xml2_1.3.4
## [55] tidyselect_1.2.0 aplot_0.1.10 farver_2.1.1
## [58] matrixStats_0.63.0 stats4_4.3.0 spatstat.explore_3.2-1
## [61] webshot_0.5.4 jsonlite_1.8.4 tidygraph_1.2.3
## [64] ellipsis_0.3.2 progressr_0.13.0 ggridges_0.5.4
## [67] survival_3.5-5 systemfonts_1.0.4 tools_4.3.0
## [70] treeio_1.24.0 ica_1.0-3 Rcpp_1.0.10
## [73] glue_1.6.2 gridExtra_2.3 xfun_0.39
## [76] qvalue_2.32.0 GenomeInfoDb_1.36.0 withr_2.5.0
## [79] formatR_1.14 fastmap_1.1.1 fansi_1.0.4
## [82] digest_0.6.31 gridGraphics_0.5-1 R6_2.5.1
## [85] mime_0.12 colorspace_2.1-0 GO.db_3.17.0
## [88] scattermore_1.1 tensor_1.5 spatstat.data_3.0-1
## [91] RSQLite_2.3.1 utf8_1.2.3 tidyr_1.3.0
## [94] generics_0.1.3 data.table_1.14.8 graphlayouts_1.0.0
## [97] httr_1.4.6 htmlwidgets_1.6.2 scatterpie_0.2.0
## [100] uwot_0.1.14 pkgconfig_2.0.3 gtable_0.3.3
## [103] blob_1.2.4 lmtest_0.9-40 XVector_0.40.0
## [106] shadowtext_0.1.2 htmltools_0.5.5 carData_3.0-5
## [109] fgsea_1.26.0 scales_1.2.1 Biobase_2.60.0
## [112] png_0.1-8 ggfun_0.0.9 rstudioapi_0.14
## [115] reshape2_1.4.4 nlme_3.1-162 cachem_1.0.8
## [118] zoo_1.8-12 KernSmooth_2.23-21 HDO.db_0.99.1
## [121] parallel_4.3.0 miniUI_0.1.1.1 AnnotationDbi_1.62.1
## [124] pillar_1.9.0 vctrs_0.6.2 RANN_2.6.1
## [127] promises_1.2.0.1 car_3.1-2 xtable_1.8-4
## [130] cluster_2.1.4 evaluate_0.21 cli_3.6.1
## [133] compiler_4.3.0 rlang_1.1.1 crayon_1.5.2
## [136] future.apply_1.11.0 ggsignif_0.6.4 labeling_0.4.2
## [139] plyr_1.8.8 stringi_1.7.12 deldir_1.0-6
## [142] BiocParallel_1.34.2 munsell_0.5.0 Biostrings_2.68.1
## [145] lazyeval_0.2.2 spatstat.geom_3.2-1 GOSemSim_2.26.0
## [148] Matrix_1.5-4 patchwork_1.1.2 bit64_4.0.5
## [151] future_1.32.0 KEGGREST_1.40.0 shiny_1.7.4
## [154] highr_0.10 ROCR_1.0-11 igraph_1.4.2
## [157] broom_1.0.4 memoise_2.0.1 bslib_0.4.2
## [160] ggtree_3.8.0 fastmatch_1.1-3 bit_4.0.5
## [163] downloader_0.4 gson_0.1.0 ape_5.7-1